/* 接口文件 */
// 导入二次封装的axios
import request from '@utils/request'
// 请求文章列表
const fetchArt = (params = {}) =>  request.get('/getArtList', { params })
// 增加文章
const addArt = (params = {}) =>  request.post('/addArt', params)
// 获取文章详情
const fetchArtDetail =  (params = {}) =>  request.get('/getArt', { params })
// 更新文章
const updateArt = (params = {}) =>  request.post('/updateArt', params)
// 删除文章
const delArt = (params = {}) =>  request.post('/delArt', params)
// 登录
const doLogin = (params = {}) => request.post('/login', params)
/* 导出接口 */
export {
  fetchArt,
  addArt,
  fetchArtDetail,
  updateArt,
  delArt,
  doLogin
}
